<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:p="http://primefaces.org/ui" 
      xmlns:ui="http://java.sun.com/jsf/facelets">
    <h:head>
        <title>Atualizar Denúncia</title>
    </h:head>
    <h:body>
        <p:panel id="panelAtualizarDenuncia" >
            <h:form id="formAtualizarDenuncia">

                    <p:spacer height="22" width="0"/>

                    <p:messages id="msgsAtualizarDenuncia" autoUpdate="true"/>
                    <p:spacer height="22" width="0"/>
                    <h:panelGrid columns="2">

                        <p:outputLabel value="Condição da Denúncia: " />
                        <p:selectOneMenu value="#{denunciaBean.denuncia.condicao}" >
                            <f:selectItems value="#{condicaoBean.listarCondicoes()}" var="condicao"
                                           itemLabel="#{condicao.nome}" itemValue="#{condicao.nome}" noSelectionValue="Nenhuma"/>
                        </p:selectOneMenu>
                        <!-- <p:message for="txtCategoria" display="both"  /> -->   

                    </h:panelGrid>

                    <h:inputHidden id="hiddenAutor" value="#{denunciaBean.denuncia.autor}" />
                    <h:inputHidden id="hiddenTipoDenuncia" value="#{denunciaBean.denuncia.tipoDenuncia}" />
                    <center> 
                        <p:commandButton id="atualizarDenunciaButton" value="Atualizar Condição"  action="#{denunciaBean.atualizarDenuncia()}" />
                    </center>

            </h:form>
        </p:panel>
    </h:body>
</html>